/*
 * @Descripttion: 
 * @Author: zhanyi
 * @Date: 2021-10-21 16:44:33
 * @FilePath: \wczd-mobile\src\api\danger.js
 */
// 引入工具类
import request from '@/utils/request.js'


// 路由权限 
export function getRouters () {
  return request({
    url: '/getRouters',
    method: 'get',
  })
}
// 添加隐患 
export function dangerInfoAdd (data) {
  return request({
    url: '/inspection/whDangerInfo/add',
    method: 'post',
    data: data
  })
}
// 隐患列表 
export function dangerInfoList (data, params) {
  return request({
    url: '/inspection/whDangerInfo/list',
    method: 'post',
    data: data,
    params: params
  })
}
// 由我发现 
export function dangerByMine (data, params) {
  return request({
    url: '/inspection/whDangerInfo/dangerByMine',
    method: 'post',
    data: data,
    params: params
  })
}
// 隐患删除 
export function dangerInfoRemove (params) {
  return request({
    url: '/inspection/whDangerInfo/remove',
    method: 'post',
    params: params
  })
}

// 隐患确认
export function confirmDanger (params) {
  return request({
    url: '/inspection/whDangerInfo/confirmDanger',
    method: 'post',
    params: params
  })
}

// 隐患单条
export function dangerInfoOne (params) {
  return request({
    url: '/inspection/whDangerInfo/one',
    method: 'post',
    params: params
  })
}

// 整改分配
export function dangerToAllot (data) {
  return request({
    url: '/inspection/whDangerInfo/dangerToAllot',
    method: 'post',
    data: data
  })
}

// 整改提交待验收
export function dangerAllotOk (data) {
  return request({
    url: '/inspection/whDangerInfo/dangerAllotOk',
    method: 'post',
    data: data
  })
}

// 整改列表
export function rectifyInfoList (data, params) {
  return request({
    url: '/inspection/whDangerRectifyInfo/list',
    method: 'post',
    data: data,
    params: params
  })
}

// 由我整改 列表
export function selectRectifyDangerToMine (data, params) {
  return request({
    url: '/inspection/whDangerRectifyInfo/selectRectifyDangerToMine',
    method: 'post',
    data: data,
    params: params
  })
}

// 由我验收 列表
export function selectCheckDangerToMine (data, params) {
  return request({
    url: '/inspection/whDangerRectifyInfo/selectCheckDangerToMine',
    method: 'post',
    data: data,
    params: params
  })
}

// 整改编辑
export function rectifyInfoEdit (data) {
  return request({
    url: '/inspection/whDangerRectifyInfo/edit',
    method: 'post',
    data: data
  })
}

// 整改单条
export function rectifyInfoOne (params) {
  return request({
    url: '/inspection/whDangerRectifyInfo/one',
    method: 'post',
    params: params
  })
}

// 整改验收通过
export function dangerAllotVerify (data) {
  return request({
    url: '/inspection/whDangerInfo/dangerAllotVerify',
    method: 'post',
    data: data
  })
}

// 隐患统计
export function statisticsDanger (data) {
  return request({
    url: '/inspection/whDangerInfo/statisticsDanger',
    method: 'post',
    data: data
  })
}